// https://nuxt.com/docs/api/configuration/nuxt-config
// 官方推荐第三方依赖 https://nuxt.com/modules
export default defineNuxtConfig({
  // 运行时控制台
  devtools: { enabled: true },
  // 插件
  modules: ["@nuxtjs/tailwindcss", "@element-plus/nuxt"],
  // 别名
  // alias: {
  //   images: resolve(__dirname, "./assets/images"),
  //   style: resolve(__dirname, "./assets/style"),
  //   data: resolve(__dirname, "./assets/other/data"),
  // },
  // 构建目录
  buildDir: "nuxt-build",
  // 页面配置
  app: {
    head: {
      title: "巧智绘",
      meta: [
        { name: "viewport", content: "width=device-width, initial-scale=1" },
        {
          hid: "description",
          name: "description",
          content:
            "巧智绘是聚焦儿童智慧场景综合服务商，以智能化游戏、数字化平台、创新型空间、特色化品牌为核心，为儿童智慧场景建设提供一站式解决方案。",
        },
        {
          hid: "keywords",
          name: "keywords",
          content:
            "巧智绘官网、巧智绘、儿童、智慧校园、数字教育、现代化幼儿园、智慧教育、AR、VR、全息、元宇宙、儿童科技玩具、学前教育、智能游戏、儿童空间设计、MI、VI、IP、SI、视频拍摄",
        },
      ],
    },
  },
  vite: {
    // api 关闭scss的警告。  注意：scss的引入换为了@use 之前是@import
    css: {
      preprocessorOptions: {
        scss: {
          api: "modern-compiler",
          additionalData: '@use "assets/styles/variable.scss" as *;',
        },
      },
    },
  },
  // 全局css
  css: ["/assets/styles/default.css"],
});
